This invention relates to an image processing apparatus and method and, more particularly to an image processing apparatus and method for forming an image based on input image information.
Printers are known which perform rasterizing based on print data in Page Description Language (hereinafter referred to as xe2x80x9cPDL dataxe2x80x9d), and supply the rasterized data to a printer engine.
These printers have the following problems:
1) To realize downsizing, cost reduction and the like of a printer controller, a printer having a small-capacity image memory (band memory) with a capacity less than the capacity for storing data for one page is provided. In this case, if the speed of rasterizing a page object is lower than the print speed of the printer engine, a print medium is discharged without forming the desired output image. This status is referred to as xe2x80x9coverrunxe2x80x9d.
2) Also, to realize downsizing, cost reduction and the like of a printer controller, there is limitation upon the capacity of an intermediate memory for temporarily storing print data received from an external device such as a computer. In this case, all the objects for one page cannot be stored into the intermediate memory, and desired printing cannot be performed. This status is referred to as xe2x80x9cmemory overflowxe2x80x9d.
In a case where the image memory has a capacity for storing data for one page, even if all the objects for one page cannot be stored in the intermediate memory, a part of the object stored in the intermediate memory can be sequentially rasterized, then the rasterized object can be sequentially deleted from the memory, and the subsequent part of the object can be stored into the intermediate memory.
However, as this method requires an image memory for one page, it is difficult to realize downsizing, cost reduction and the like for a printer controller.
The present invention has been made in consideration of the above situation, and has its object to prevent occurrence of overrun and memory overflow while reducing the capacity of a memory resource for image processing.
According to the present invention, the foregoing object is attained by providing an image processing apparatus for generating an image based on image information, comprising: input means for inputting image information; an image information memory for temporarily storing the image information; an image memory for storing image data, having a capacity less than a capacity for storing image data for one page; rendering means for rendering image data in the image memory based on the image information stored in the image information memory; compressing means for compressing the image data in the image memory and sequentially storing the compressed image data into a compressed image memory; expanding means for expanding the compressed image data stored in the compressed image memory; and output means for outputting an image based on the image data expanded by the expanding means onto a print medium, wherein the expanding means continuously expands the compressed image data stored in the compressed image memory and supplies the expanded image data to the output means.
Preferably, in the image processing apparatus, the expanding means continuously expands the compressed image data for one page and supplies the expanded image data to the output means.
Preferably, in the image processing apparatus, after the compressed image data for one page has been stored into the compressed image memory, the expanding means continuously expands the compressed image data and supplies the expanded image data to the output means.
Preferably, the image processing apparatus further comprises analyzing means for estimating processing time for rendering by the rendering means, wherein the compressing means and the expanding means are controlled based on the processing time estimated by the analyzing means, so as to prevent overrun of the output means.
Preferably, in the image processing apparatus, if the processing time estimated by the analyzing means is less than a predetermined value, the image data generated by the rendering means is directly supplied to the output means, while if the processing time is greater than the predetermined value, the compressing means sequentially compresses the image data and stores the compressed image data into the compressed image memory, thereafter, the expanding means continuously expands the image data and supplies the expanded image data to the output means.
Preferably, in the image processing apparatus, the expanding means continuously expands the compressed image data for one page and supplies the expanded image data to the output means.
Preferably, in the image processing apparatus, after the compressed image data for one page has been stored into the compressed image memory, the expanding means continuously expands the compressed image data and supplies the expanded image data to the output means.
Preferably, the image processing apparatus further comprises available-capacity detecting means for detecting an available capacity of the image information memory, wherein the input means, the rendering means, the compressing means and the expanding means are controlled based on the available capacity detected by the available-capacity detecting means, so as to prevent overflow of the image information memory.
Preferably, in the image processing apparatus, when the available capacity of the image information memory becomes less than a predetermined amount,
input of the image information by the input means is stopped, then image data is rendered in the image memory based on the image information stored in the image information memory up to that time, and the image data is compressed and stored into the compressed image memory,
next, the image data for one page is formed in the compressed image memory by repeating operations of: inputting subsequent image information by the input means until it is detected that the available capacity of the image information memory is less than a predetermined amount; storing the subsequent image information into the image information memory in place of the image information used in rendering by the rendering means; specifying an image area corresponding to the subsequent image information; expanding the image data at the image area stored in the compressed image memory and re-writing the image data in the image memory, while rendering image data in the image memory based on the subsequent image information; and compressing image data obtained from combination of the image data re-written in the image memory and the image data rendered in the image memory based on the subsequent image information by the compressing means, and storing the compressed image data into the compressed image memory, and
the expanding means continuously expands the image data and supplies the expanded data to the output means for one page.
Preferably, in the image processing apparatus, the image memory has at least two band memories, so that the image data is outputted from one band memory while rendered image data is stored in the other band memory, and wherein the image area corresponds to a capacity of the one band memory.
Preferably, in the image processing apparatus, the image memory has at least two band memories, so that the image data is outputted from one band memory while rendered image data is stored in the other band memory.
Preferably, the image processing apparatus further comprises analyzing means for estimating processing time for rendering by the rendering means and available-capacity detecting means for detecting an available capacity of the image information memory, wherein the input means, the rendering means, the compressing means and the expanding means are controlled based on the processing time estimated by the analyzing means and the available capacity detected by the available-capacity detecting means, so as to prevent overrun of the output means and memory overflow of the image information memory.
Preferably, in the image processing apparatus, the compressing means includes means for converting the image data supplied from the rendering means into low resolution image data.
Preferably, in the image processing apparatus, the expanding means includes means for converting low resolution image data into high resolution image data.
Preferably, the image processing apparatus further comprises data amount control means for converting image object data included in the image information inputted by the input means into low resolution data and storing the low resolution data into the image information memory.
Preferably, in the image processing apparatus, the data amount control means includes data amount predicting means for predicting a data amount of image object data to be inputted, and wherein the data amount control means converts image object data, having a data amount predicted by the data amount predicting means as greater than a predetermined amount, into low resolution data.
Preferably, in the image processing apparatus, the output means forms an output image in a print medium by an electrophotographic method.
Further, the present invention provides an image processing method for generating an image based on image information, comprising: an input step of inputting image information; a storage step of temporarily storing the image information into an image information memory; a rendering step of rendering image data in an image memory having a capacity less than a capacity for storing image data for one page, based on the image information stored in the image information memory; a compressing step of compressing the image data in the image memory and sequentially stores the compressed image data into a compressed image memory; an expanding step of expanding the compressed image data stored in the compressed image memory; and an output step of outputting an image based on the image data expanded by the expanding means onto a print medium, wherein at the expanding step, the compressed image data stored in the compressed image memory is continuously expanded and supplied to the output step.
Further objects, features and advantages of the present invention will become apparent from the following detailed description of embodiments of the present invention with reference to the accompanying drawings.